package com.person.config;

import org.springframework.cloud.gateway.route.RouteLocator;
import org.springframework.cloud.gateway.route.builder.RouteLocatorBuilder;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author    zhangfc
 * @date 2021/6/21 15:23
 */
@Configuration
public class CloudGateWayConfiger {
    @Bean
    public RouteLocator routes(RouteLocatorBuilder builder) {
        return builder.routes()
                .route("payment_routh1",
                        r -> r.path("/guonei").uri("http://news.baidu.com/guonei")).build();
    }

}
